﻿<Window x:Class="TicTacToe.UI.NetLobbyWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:extToolkit="http://schemas.xceed.com/wpf/xaml/toolkit"
        ResizeMode="CanMinimize" Title="Game Lobby" Height="340" Width="380"
        Icon="..\3dtictactoe.png"
        x:ClassModifier="internal" WindowStartupLocation="CenterScreen">
    <Grid Name="windowGrid">
        <Grid.RowDefinitions>
            <RowDefinition Height="3*" />
            <RowDefinition Height="4*" />
            <RowDefinition Name="startRow" Height="30" />
        </Grid.RowDefinitions>

        <GroupBox Header="Players" Margin="4,4,4,2">
            <Grid>
                <Grid.RowDefinitions>
                    <RowDefinition />
                    <RowDefinition />
                </Grid.RowDefinitions>

                <Border Style="{StaticResource borderStyle}" Margin="4,4,4,2" Grid.Row="0">
                    <Grid>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition />
                            <ColumnDefinition Width="3*" />
                        </Grid.ColumnDefinitions>
                        
                        <Label Grid.Column="0" Content="Host" Foreground="White" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="20" />
                        <Border Name="hostBorder" Grid.Column="1"  Margin="4" CornerRadius="4">
                            <Viewbox>
                                <ContentControl Name="hostContentControl" Foreground="Black" />
                            </Viewbox>
                        </Border>
                        
                    </Grid>
                </Border>

                <Border Style="{StaticResource borderStyle}" Margin="4,2,4,4" Grid.Row="1">
                    <Grid>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition />
                            <ColumnDefinition Width="3*" />
                        </Grid.ColumnDefinitions>
                        
                        <Label Grid.Column="0" Content="Client" Foreground="White" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="20" />
                        <Border Name="clientBorder" Grid.Column="1"  Margin="4" CornerRadius="4">
                            <Viewbox>
                                <ContentControl Name="clientContentControl" Foreground="Black" />
                            </Viewbox>
                        </Border>
                    </Grid>
                </Border>
            </Grid>
        </GroupBox>
        
        <GroupBox Header="Chat"  Margin="4,2,4,4" Grid.Row="1">
            <Grid Margin="3">
                <TextBox Name="historyTextBox" IsReadOnly="True" Margin="0,0,0,29" TextWrapping="Wrap" VerticalScrollBarVisibility="Auto" />
                <extToolkit:WatermarkTextBox Name="chatMessageTextBox" Watermark="Enter chat messages here" Height="23" Margin="0,0,81,0" VerticalAlignment="Bottom" PreviewKeyDown="chatMessageTextBox_PreviewKeyDown"  />
                <Button Style="{StaticResource buttonStyle}" Height="23" Width="75" Content="Send" HorizontalAlignment="Right" VerticalAlignment="Bottom" Click="Button_Click" />
            </Grid>
        </GroupBox>
        
        <Button Style="{StaticResource buttonStyle}" Name="startButton" Grid.Row="2" Width="75" Height="22" Content="Start" IsEnabled="False" Click="startButton_Click" />
    </Grid>
</Window>
